import { Component, OnInit } from '@angular/core';

@Component({
  selector: 'app-equipment-search',
  templateUrl: './equipment-search.component.html',
  styleUrls: ['./equipment-search.component.scss']
})
export class EquipmentSearchComponent implements OnInit {
  queryModel;
  cols;
  assets;
  moreSearchIsShow: boolean = false;
  constructor() { }

  ngOnInit() {
    this.queryModel = {
      "ano":"",
      "father":"",
      "card_position":"",
      "asset_no":"",
      "name":"",
      "brand":"",
      "modle":"",
      "function":"",
      "system":"",
      "status":"",
      "on_line_date_start":"",
      "on_line_date_end":"",
      "room":"",
      "cabinet":"",
      "location":"",
      "belong_dapart":"",
      "belong_dapart_manager":" ",
      "manage_dapart":"",
      "manager":"",
      "ip":"",
      "maintain_vender":""
    }
    this.cols = [
      {field: 'ano', header: '设备编码'},
      {field: 'father', header: '从属于'},
      {field: 'asset_no', header: '固定资产编号'},
      {field: 'name', header: '设备名称'},
      {field: 'status', header: '设备状态'},
      {field: 'room', header: '机房'},
      {field: 'cabinet', header: '机柜'},
      {field: 'location', header: 'U位'},
      {field: 'ip', header: '管理IP'},
   ];
  }
  toggleMoreSearch() {
    this.moreSearchIsShow = this.moreSearchIsShow ? false : true;
  }
}
